Android Recipes by Dave Smith with Jeff Friesen

Android Recipes by Dave Smith with Jeff Friesen

Author:Dave Smith with Jeff Friesen
Language: eng
Format: mobi
ISBN: 9781430263227
Publisher: Apress


for (int i = 0; i < device.getInterfaceCount(); i++) {

UsbInterface intf = device.getInterface(i);

sb.append( String.format(

"+--Interface %d Class: %s -> "

+ "Subclass: 0x%02x -> Protocol: 0x%02x\n",

intf.getId(),

nameForClass(intf.getInterfaceClass()),

intf.getInterfaceSubclass(),

intf.getInterfaceProtocol())

);

for (int j = 0; j < intf.getEndpointCount(); j++) {

UsbEndpoint endpoint = intf.getEndpoint(j);

sb.append( String.format(

" +---Endpoint %d: %s %s\n",

endpoint.getEndpointNumber(),

nameForEndpointType(endpoint.getType()),

nameForDirection(endpoint.getDirection()))

);

}

}



Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.